package com.handyshop.mall.basic.core.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 分页条件
 *
 * @author hanshuai
 */
@Data
@ApiModel(description = "分页参数")
public class PageBean implements Serializable {

    @NotNull(message = "当前页数 不能为空")
    @ApiModelProperty(value = "当前页数")
    private Integer pageNum = 1;

    @NotNull(message = "条数 不能为空")
    @Max(value = 500, message = "条数不能大于500")
    @ApiModelProperty(value = "条数")
    private Integer pageSize = 10;
}